﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace AjaxToolkitDemo
{
    public partial class AutoComplete : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {

        }

        [System.Web.Script .Services.ScriptMethod]
        [System.Web.Services.WebMethod]
        public static   string[] GetAutoCompleteList(string prefixText, int count)
        {
            List<string> list = new List<string>();
            for (int i = 0; i < 10; i++)
            {
                list.Add ( string.Format( "pre:{0},count:{1}",prefixText,count));
            }
            return list.ToArray();
        }
    }
}
